// Decompiled on 周六 2月 22 19:31:49 CST 2025 with Zomboid Decompiler v0.1.3 using Vineflower.
package zombie.sandbox;

import zombie.scripting.ScriptParser;

public final class CustomBooleanSandboxOption extends CustomSandboxOption {
    public final boolean defaultValue;

    CustomBooleanSandboxOption(String string, boolean _boolean) {
        super(string);
        this.defaultValue = _boolean;
    }

    static CustomBooleanSandboxOption parse(ScriptParser.Block block) {
        ScriptParser.Value value = block.getValue("default");
        if (value == null) {
            return null;
        } else {
            boolean _boolean = Boolean.parseBoolean(value.getValue().trim());
            CustomBooleanSandboxOption customBooleanSandboxOption = new CustomBooleanSandboxOption(block.id, _boolean);
            return !customBooleanSandboxOption.parseCommon(block) ? null : customBooleanSandboxOption;
        }
    }
}
